package com.mmd.manage.web;

import com.mmd.bean.CODE;
import com.mmd.bean.WebJsonBean;
import com.mmd.manage.service.MmdMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * 菜单
 */
@RequestMapping(value = "/api/menu")
@Controller
public class MenuController {

    @Autowired
    private MmdMenuService menuService;


    /**
     * 获取菜单
     *
     * @return
     */
    @RequestMapping(value = "/getMenuList")
    @ResponseBody
    public WebJsonBean getMenuList() {
        return new WebJsonBean(CODE.SUCCESS, menuService.getMenuList());
    }

}
